<template>
  <div class="bw-group-item-container">
    <div class="bw-group-item-label-wrap">
      <span class="bw-group-item-label-text">
        {{ title }}
      </span>

      <template v-if="remar">
        <Tooltip :title="remar">
          <question-circle-outlined />
        </Tooltip>
      </template>
    </div>

    <div class="bw-group-item-content">
      <slot></slot>
    </div>
  </div>
</template>
<script lang="ts" setup>
import { Tooltip } from 'ant-design-vue'
import { QuestionCircleOutlined } from '@ant-design/icons-vue'

interface BwGroupItemProps {
  title: string
  remar?: string
}
const emit = defineEmits([])
withDefaults(defineProps<BwGroupItemProps>(), {
  title: '',
})

defineExpose({})
</script>

<style lang="less" scoped>
.bw-group-item-container {
  width: 100%;
  display: flex;
  flex-direction: column;

  .bw-group-item-label-wrap {
    display: flex;
    align-items: center;
    justify-content: flex-start;

    .bw-group-item-label-text {
      margin-top: 8px;
      margin-right: 8px;
      line-height: 32px;
    }
  }
}
</style>
